package com.ncdnapp.core.entity.dto;

import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.List;

/**
 * @author chenbin
 * @date 2018/5/6
 * @time 0:36
 * @Description: ${TODO}
 */
@Data
@Accessors(chain = true)
public class PageResultDTO<T> extends PageDTO implements Serializable {
    private List<T> data;
    //总页数
    private Long totalPage;
    //数据总条数
    private Long totalRow;

    public PageResultDTO(Long pageNow, Long pageSize, Long totalPage, Long totalRow, List<T> data) {
        this.setPageNow(pageNow);
        this.setPageSize(pageSize);
        this.setTotalPage(totalPage);
        this.setTotalRow(totalRow);
        this.setData(data);
    }
}
